import React, { Component } from 'react';
import '../styles/MyToday.scss'
import pic from '../assets/2.png'

class MyToday extends Component {
  constructor(props) {
    super(props)
    this.state = {
      list: [
        { pic, name: '菲洛嘉柔面膜', yuanjia: 303, money: 195 },
        { pic, name: '眼霜', yuanjia: 924, money: 675 },
        { pic, name: '海蓝', yuanjia: 303, money: 2543 },
        { pic, name: '不知道啥玩意', yuanjia: 430, money: 413 },
        { pic, name: '这个也不知道', yuanjia: 110, money: 93 },
        { pic, name: '蓝宝石', yuanjia: 1749, money: 1487 },

      ]
    }
  }
  render() {
    return (
      <div className='today'>
        <div className='buy'>
          <p className='zuo'>今日值得买</p>
          <p className='you'>MORE→</p>
        </div>
        <div className='list1'>
          {
            this.state.list.map((item, index) => {
              return (
                <div className="item1" key={index}>
                  <img src={item.pic} alt="" />
                  <p className='p1'>{item.name}</p>
                  <p className='p2'>原价 ￥{item.yuanjia}</p>
                  <p className='p3'>抢购价￥<span>{item.money}</span></p>
                </div>

              )

            })
          }
        </div>
      </div>
    );
  }
}

export default MyToday;